<extend name="Public/base"/>
<block name="body">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>菜单列表</h5>

                </div>
                <div class="ibox-content">
                    <div class="row">

                        <div class="col-sm-3" >

                            <div class="input-group"  >


                                <input type="text" placeholder="请输入关键词" class="input-sm form-control"> <span class="input-group-btn" >
                                        <button type="button" class="btn btn-sm btn-primary"> 搜索</button> </span>&nbsp;&nbsp;&nbsp;&nbsp;
                                <span class="input-group-btn" ><button type="button" onClick="window.location.href='{:U('add')}'" class="btn btn-sm btn-primary" style="background-color: #00b7ee"> 添加菜单</button> </span>
                            </div>
                        </div>

                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped" align="center">

                            <tr align="center" class="font-bold">
                                <td>序号</td>
                                <td>菜单名称</td>
                                <td>对应地址</td>
                                <td>是否隐藏</td>
                                <td>操作</td>
                            </tr>

                            <tbody>
                            <volist name="menu" id="menu">
                            <tr align="center">
                                <td>
                                    {$menu.id}
                                </td>
                                <td>{$menu.menu_name}</td>
                                <td>{$menu.linkurl}</td>
                                <td>
                                    <if condition="menu.hide eq 0">
                                        <font color="#32cd32">否</font>
                                    <else/>
                                        <font color="red">是</font>
                                    </if>
                                </td>
                                <td>
                                    <a href="{:U('Menu/edit',array('id'=>$menu['id']))}"><i class="fa fa-check text-navy">编辑</i></a>
                                    <a href="{:U('del',array('id'=>$menu['id']))}" onclick="return chkget({$menu.id});" id="{$menu.id}"><i class="fa fa-times" style="color:red">删除</i></a>
                                </td>
                            </tr>
                            </volist>

                            </tbody>
                        </table>
                    </div>

                    <div class="_page">{$_page}</div>

                </div>
            </div>
        </div>

    </div>
    <script>
        $('#1').attr('class','active');
    </script>
</block>